//
//  SmartSearchView.m
//  Zinipad
//
//  Created by ZeLkOvA on 12. 5. 23..
//  Copyright (c) 2012년 __MyCompanyName__. All rights reserved.
//

#import "SmartSearchView.h"

@interface SmartSearchView ()

@end

@implementation SmartSearchView

- (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil
{
    self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil];
    if (self) {
        // Custom initialization
    }
    return self;
}

- (void)viewDidLoad
{
    [super viewDidLoad];
    
    UIButton* BackButtonPressed = [UIButton buttonWithType:UIButtonTypeRoundedRect];
    [BackButtonPressed setFrame:CGRectMake(10, 10 , 100, 36)];
    [BackButtonPressed setTitle:[NSString stringWithFormat:@"이전"] forState:UIControlStateNormal];
    [BackButtonPressed setTitleColor:[UIColor blackColor] forState:UIControlStateNormal];
    [BackButtonPressed setContentHorizontalAlignment:UIControlContentHorizontalAlignmentLeft];
    [BackButtonPressed setTitleEdgeInsets:UIEdgeInsetsMake(5, 45, 5, 5)];
    [BackButtonPressed addTarget:self action:@selector(BackButtonPressed:) forControlEvents:UIControlEventTouchUpInside];
    [self.view addSubview:BackButtonPressed];
	// Do any additional setup after loading the view.
}

- (void)viewDidUnload
{
    [super viewDidUnload];
    // Release any retained subviews of the main view.
}

- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation
{
    return (interfaceOrientation == UIInterfaceOrientationPortrait);
}

-(void)BackButtonPressed:(id)sender
{
     [self.navigationController popViewControllerAnimated:YES];  
}
@end
